/*
 * @Autor: dc
 * @Date: 2022-03-30 17:18:45
 * @LastEditors: dc
 * @LastEditTime: 2022-04-01 14:15:24
 * @Description: 
 */


import React, { Component } from 'react'
import {Route,Redirect} from 'react-router-dom'
import './App.css';
import Scenario from './pages/Scenario';
import Home from './pages/Home';

import './utils/rem.js'
import store from './redux/store.js'

export default class App extends Component {
  constructor(props){
    super(props)
    store.dispatch({
      type: 'Initialize',
      data: ''
    })
  }
  componentWillUnmount() {
    store.dispatch({
      type: 'StoreData',
      data: '',
    })
  }
  render() {
    return (
      <div className="App">
        {/* <Home></Home> */}
        {/* <Scenario></Scenario> */}
        <Route path='/home' component={Home} ></Route>
        <Route path='/scenario' component={Scenario} ></Route>
        <Redirect to="/home"></Redirect>
      </div>
    )
  }
}
